<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<title></title>
<#include "/jspgou_sys/head.html"/>
<script type="text/javascript">
function getTableForm() {
	return document.getElementById('tableForm');
}
function optDelete() {
	if(Pn.checkedCount('ids')<=0) {
		alert("<@s.m 'error.checkRecord'/>");
		return;
	}
	if(!confirm("<@s.m 'global.confirm.delete'/>")) {
		return;
	}
	var f = getTableForm();
	f.action="o_delete.do";
	f.submit();
}
function opSendEmail() {
	if(Pn.checkedCount('ids')<=0) {
		alert("请选择您要操作的数据");
		return;
	}
	if(!confirm("您确定要发送到货通知吗?")) {
		return;
	}
	var f = getTableForm();
	f.action="o_senderEmail.do";
	f.submit();
}



</script>
</head>
<body>
<div class="body-box">
<div class="rhead">
	<div class="rpos"><@s.m "global.position"/>: 到货通知 - <@s.m "global.list"/></div>
	<div class="clear"></div>
</div>
<form id="tableForm" method="post">
<input type="hidden" name="pageNo" value="${pageNo!}"/>
<@p.table value=pagination;noctice,i,has_next><#rt/>
	<@p.column title="<input type='checkbox' onclick='Pn.checkbox(\"ids\",this.checked)'/>" width="20">
		<input type='checkbox' name='ids' value='${noctice.id}'/><#t/>
	</@p.column><#t/>
	<@p.column code="ID" align="center"> ${noctice.id} </@p.column><#t/>
	<@p.column code="商品名称" align="center"><a href="${noctice.product.url}" target="_blank" style="color: #336699;font-size: 15px;; "> ${noctice.product.name} </a></@p.column><#t/>
	<@p.column code="电子邮箱" align="center">${noctice.user.email}</@p.column><#t/>
	 <@p.column code="登记时间" align="center">${noctice.registerTime?string('yyyy-MM-dd ')}</@p.column><#t/> 
	 	<@p.column code="状态" align="center"> <#if (noctice.product.stockCount>=1)>已上架<#else><a style="color: red">缺货<a/></#if></@p.column><#t/>
	  <@p.column code="通知时间" align="center"><#if noctice.nocticeTime??> ${noctice.nocticeTime?string('yyyy-MM-dd ')}<#else> --- </#if></@p.column><#t/> 	 
</@p.table>
<div><input type="button" value="<@s.m "global.delete"/>" onclick="optDelete();"/>  <a><input type="button" value="发送到货通知" onclick="opSendEmail();"/></a></div>

</form>
</div>
<#include "/common/alert_message.html"/>
</body>
</html>